import {request} from "@/utils/request.ts";



// User

export async function userSaveReq(
    body: Partial<API.UserSaveReq>,
    options?: { [p: string]: never }
) {
    return request<BaseResp<API.UserSaveResp>>({
        url: `/api/v1/admin/user/save`,
        method: 'POST',
        data: body,
        ...(options || {}),
    });
}

export async function userListReq(
    body: Partial<API.UserListReq>,
    options?: { [p: string]: never }
) {
    return request<BaseResp<API.UserListResp>>({
        url: `/api/v1/admin/user/list`,
        method: 'POST',
        data: body,
        ...(options || {}),
    });
}

export async function userDeleteReq(
    body: Partial<API.UserDeleteReq>,
    options?: { [p: string]: never }
) {
    return request<BaseResp<API.UserDeleteResp>>({
        url: `/api/v1/admin/user/delete`,
        method: 'POST',
        data: body,
        ...(options || {}),
    });
}


// Role
